<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<html lang="en">
<head>
	<meta http-equiv="Content-Type" content="text/html;charset=UTF-8">
	<title>文件管理系统</title>
	<link rel="stylesheet" href="Tpl/css/bootstrap.min.css">
	<link rel="stylesheet" href="Tpl/js/bootstrap.min.js">
	<style type="text/css">
        .panel-default{
        	width:600px;height:600px;margin:100px auto;
        }
        .panel-heading{
        	text-align:center;
        }
        .father{
        	position: relative;
        }
        .son{
        	position:absolute;top:20px;right:0px;
        }
        tr{
        	width:600px;
        }
        td{
        	width:120px;text-align: center;
        }

        #show{
        	width:100px;height:25px;background:#EBEBEB;text-align: center;line-height:25px;
        	position: relative;top:20px;border:1px solid #999;
        }
        .main{
        	width: 100px;height: 25px;background: red;position:relative;top:-10px;opacity:0;
        }

	</style>
</head>
<body>


	<div class="panel panel-default">
	    <!-- Default panel contents -->
	    <div class="panel-heading">个人网盘</div>
	    <div class="panel-body">
	        <form action="upload.php" method="post" enctype="multipart/form-data" class="father">
	       <!--  <input type="hidden" name="MAX_FILE_SIZE" value="300000">  -->
	            <div id="show">选择文件</div>
		    	<input type="file" name='myfile[]' multiple='multiple' class="main">
		    	<!-- <input type="file" name='myfile[]'>
		    	<input type="file" name='myfile[]'>
		    	<input type="file" name='myfile[]'>
		    	<input type="file" name='myfile[]'> -->
		    	<input type="submit" name='sub' value='上传' class="son">
            </form>
	    </div>

	    <!-- Table -->
	    <table class="table">
	        <tr>
	            <td>img</td>
	        	<td>type</td>
	        	<td>size</td>
	        	<td>time</td>
	        	<td>handle</td>
	        </tr>
  
            <?php foreach ($img as $key => $value) {  ?>

            	<tr>
		        	<td><img src="<?php echo $value ?>" alt="" width='30' height='30' ></td>
		        	<td><?php  $last=explode('.',basename($value));echo end($last);  ?></td>
		        	<td><?php echo ChangeDanWei(filesize($value)); ?></td>
		        	<td ><?php echo date('Y-m-d H:i:s',filemtime($value)); ?></td>
		        	<td>
		        		<a href="del.php?id=<?php echo $key ?>">删除</a>
		        	    <a target="_blank" href="download.php?id=<?php echo $key ?>">下载</a>
		        	</td>
	        	
	           </tr>
            	
            <?php } ?>
	       
	       
	    </table>
	</div>
	
</body>
</html>